package com.gtw.modules.api.service.impl;

import com.gtw.modules.api.service.TbLikeService;
import com.gtw.modules.dao.TbLikeMapper;
import com.gtw.modules.entity.TbLike;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("tblikeservice")
public class TbLikeServiceImpl implements TbLikeService {

    @Autowired
    private TbLikeMapper tbLikeMapper;

    @Override
    public int deleteByPrimaryKey(Integer id) {
        return tbLikeMapper.deleteByPrimaryKey(id);
    }

    @Override
    public int insert(TbLike record) {
        return tbLikeMapper.insert(record);
    }

    @Override
    public int insertSelective(TbLike record) {
        return tbLikeMapper.insertSelective(record);
    }

    @Override
    public TbLike selectByPrimaryKey(Integer id) {
        return tbLikeMapper.selectByPrimaryKey(id);
    }

    @Override
    public int updateByPrimaryKeySelective(TbLike record) {
        return tbLikeMapper.updateByPrimaryKeySelective(record);
    }

    @Override
    public int updateByPrimaryKey(TbLike record) {
        return tbLikeMapper.updateByPrimaryKey(record);
    }

    @Override
    public TbLike selectByUid(String uid, Integer discussid) {
        return tbLikeMapper.selectByUid(uid, discussid);
    }

    @Override
    public List<TbLike> selectByDiscussid(Integer discussid) {
        return tbLikeMapper.selectByDiscussid(discussid);
    }
}
